<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8" />
		<title></title>
		<script src="https://cdn.jsdelivr.net/npm/vue@2.6.14/dist/vue.js"></script>
	</head>
	<body>
		<div id="app">
			<h3>用户姓名:<input type="text" name="uname" v-model.lazy="uname" /></h3>
			<h3>用户年龄:<input type="text" name="age" v-model.number="age" /></h3>
			<h3>用户性别:<input type="radio" name="sex" value="man" v-model="sex" />男
				<input type="radio" name="sex" value="voman" v-model="sex" />女
			</h3>
			<h3>用户爱好:<input type="checkbox" name="hobby" value="html" v-model="hobby" />HTML
				<input type="checkbox" name="hobby" value="vue" v-model="hobby" />VUE
			</h3>
			<h3>用户介绍:<textarea v-model.trim="desc"></textarea></h3>

			<h2>{{uname}}</h2>
			<h2>{{age + 1}}</h2>
			<h2>{{sex}}</h2>
			<h2>{{hobby}}</h2>
			<h2>{{desc}}</h2>
		</div>
		<script type="text/javascript">
			let vm = new Vue({
				el: '#app',
				data: {
					uname: '张三1',
					age: 20,
					sex: 'man',
					hobby: ['vue'],
					desc: '我的介绍'
				}
			})
		</script>
	</body>
</html>
